package com.lesshassles.util;

import javax.servlet.http.HttpServletRequest;

import com.lesshassles.model.User;

/**
 * Manages setting, getting and removal of Employee object
 * in a HTTP session.
 * @author David Santoro
 * @see com.lesshassles.model.User
 */
public class ApplicationSecurityManagerImpl implements ApplicationSecurityManager
{
	public User getUser(HttpServletRequest request) {
	    return (User)request.getSession(true).getAttribute(USER);
	}

	public void setUser(HttpServletRequest request, User user) {
	    request.getSession(true).setAttribute(USER, user);
	}

	public void removeUser(HttpServletRequest request) {
	    //request.getSession(true).removeAttribute(USER);
	}
}
